
    /***
     *
     * g：性能测试
     *
     */

    var mark;
    var measure;

    {
        var perf = inBrowser && window.performance;

        /* istanbul ignore if */
        if (
            perf &&
            perf.mark &&
            perf.measure &&
            perf.clearMarks &&
            perf.clearMeasures
        ) {
            mark = function(tag) { 
                return perf.mark(tag); 
            };
            measure = function(name, startTag, endTag) {
                perf.measure(name, startTag, endTag);
                perf.clearMarks(startTag);
                perf.clearMarks(endTag);
                perf.clearMeasures(name);
            };
        }
    }